package com.jack.leetcode.eachProblem07;

/**
 * Created by zhang_j on 2020/7/22
 */
public class 旋转数组的最小数字 {

    public int minArray(int[] numbers) {
        int n = numbers.length;
        int min = numbers[0];
        for(int i = 0;i < n-1;i++){
            if(numbers[i] > numbers[i+1]){
                min = Math.min(numbers[i+1], min);
            }
        }
        return min;
    }
}
